package structuralpattern.flyweight;

public class Test {
    public static void main(String[] args) {
        BoxFactory instance = BoxFactory.getInstance();
        // box是已存在的内部数据，color是随着环境会变化的外部数据
        instance.getBox("L").display("red");
        instance.getBox("I").display("blue");
        instance.getBox("O").display("yellow");
    }
}
